/*
 * @Author: your name
 * @Date: 2021-03-02 09:46:29
 * @LastEditTime: 2021-05-13 11:57:39
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \admin_front_end\src\api\user.js
 */
import { axios } from '@/utils/request'

const api = {
  getAdminList: '/store-admin/get-admin-list',
  getInfo: '/store-admin/get-info',
  save: '/store-admin/save',
  setPassword: '/store-admin/set-password',
  setStatus: '/store-admin/set-status',
  del: '/store-admin/del'
}

export default api

export function getAdminList (parameter) {
  return axios({
    url: api.getAdminList,
    method: 'get',
    params: parameter
  })
}
export function getInfo (parameter) {
  return axios({
    url: api.getInfo,
    method: 'get',
    params: parameter
  })
}

export function save (parameter) {
  return axios({
    url: api.save,
    method: 'post',
    data: parameter
  })
}

export function setPassword (parameter) {
  return axios({
    url: api.setPassword,
    method: 'post',
    data: parameter
  })
}
export function setStatus (parameter) {
  return axios({
    url: api.setStatus,
    method: 'post',
    data: parameter
  })
}

export function del (parameter) {
  return axios({
    url: api.del,
    method: 'get',
    params: parameter
  })
}
